package cn.duli.myvideo.service.Impl;

import cn.duli.myvideo.mapper.TvMapper;
import cn.duli.myvideo.pojo.Tv;
import cn.duli.myvideo.service.TvService;
import com.github.pagehelper.Page;
import org.springframework.stereotype.Service;

import javax.annotation.Resource;
import java.util.List;


@Service
public class TvServiceImpl implements TvService {

    @Resource
    private TvMapper tvMapper;

    @Override
    public List<Tv> queryLike(String tvName) {
        return tvMapper.queryLike(tvName);
    }

    @Override
    public Page<Tv> findAll() {
        return tvMapper.findAll();
    }

    @Override
    public Tv findById(Integer tvId) {
        return tvMapper.findById(tvId);
    }

    @Override
    public void save(Tv tv) {
        tvMapper.save(tv);
    }

    @Override
    public void update(Tv tv) {
        tvMapper.update(tv);
    }

    @Override
    public void deleteById(Integer tvId) {
        tvMapper.deleteById(tvId);
    }
}
